import json

with open('test.json','r',encoding='utf-8')as f:
    data = json.load(f)
    for item in data:
        with open(f"output/{item['病历编号']}.txt",'w',encoding='utf-8') as fw:
            fw.write(str(item))
